//
//  MainTableView.swift
//  ShiZhe
//
//  Created by 陈卿伟 on 16/8/25.
//  Copyright © 2016年 陈卿伟. All rights reserved.
//

import UIKit

class MainTableView: UITableView {
    var refresh:UIRefreshControl!
    override init(frame: CGRect, style: UITableViewStyle) {
        super.init(frame: frame, style: style)
        self.backgroundColor = Theme.BGColor
        self.addRefreshControll()
        self.settingSeparatorColor()
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    
    //添加refreshControll
    func addRefreshControll(){
        refresh = UIRefreshControl()
        refresh.attributedTitle = NSAttributedString(string: "继续下拉即可刷新")
        self.addSubview(refresh)
    }
    
    //设置分割条颜色
    func settingSeparatorColor(){
        self.separatorColor = Theme.BGColor
    }
}





